﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace WJP.Logging
{
    [Serializable]
    public class EventLogLoggerFactory : AbstractLoggerFactory
    {
        private const string DefaultLogName = "WJPDefaultLogger";

        public override ILogger Create(string name)
        {
            return Create(name, LogLevel.Debug);
        }

        public override ILogger Create(string name, LogLevel level)
        {
            var logger = new EventLogLogger(DefaultLogName, name);
            logger.Level = level;
            return logger;
        }
    }
}
